// 此处存放登录相关的接口请求
import request from '@/utils/request'
// 1、获取图像验证码
export const getPicCode = () => {
  return request.get('/captcha/image')
}
// 2、 获取短信验证码
export const getMsgCode = (captchaCode, captchaKey, mobile) => {
  return request.post('/captcha/sendSmsCaptcha', {
    form: {
      captchaCode,
      captchaKey,
      mobile
    }
  })
}
// 3、登录接口
export const codeLogin = (smsCode, mobile) => {
  return request.post('/passport/login', {
    form: {
      smsCode,
      mobile,
      isParty: false, // 三方登录
      partyData: {} // 无三方登录 默认{空}
    }
  })
}
